package com.atguigu.yygh.order.service;

import com.atguigu.yygh.model.order.OrderInfo;
import com.atguigu.yygh.vo.order.OrderCountQueryVo;
import com.atguigu.yygh.vo.order.OrderQueryVo;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

import java.util.Map;

/**
 * @author DongYu Zhou
 * @date 2022/7/7 21:18
 */
public interface OrderService extends IService<OrderInfo> {
    /**
     * 创建订单
     * @param scheduleId
     * @param patientId
     * @return
     */
    Long submitOrder(String scheduleId, Long patientId);

    /**
     * 带条件带分页的查询订单
     * @param infoPage
     * @param orderQueryVo
     * @return
     */
    Page<OrderInfo> selectPage(Page<OrderInfo> infoPage, OrderQueryVo orderQueryVo);

    /**
     * 根据id获取订单信息详情
     * @param orderId
     * @return
     */
    OrderInfo getOrderInfo(Long orderId);

    boolean cancelOrder(Long orderId);

    /**
     * 就诊提醒
     */
    void patientTips();

    Map<String, Object> getCountMap(OrderCountQueryVo orderCountQueryVo);

}
